<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <meta http-equiv="X-UA-Compatible" content="IE=edge">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>多类名的使用</title>

    <style>
        .box {
            width: 100px;
            height: 100px;
        }
        .greenyellow {
            background-color: greenyellow;
        }
        .back-red {
            background-color: red;
        }
        .red {
            color: red;
        }
        .font35 {
            font-size: 35px;
        }
    </style>

</head>
<body>
    <h3>1.在标签class属性中写多个类名</h3>
    <h3>2.多个类名用空格分开</h3>
    <h3>标签就可以分别具有这些类名的样式</h3>
    
    <div class="red font35">例子一</div>

    <div class="box back-red">例子二,div1</div>
    <div class="box greenyellow">例子二,div2</div>
    <div class="box back-red">例子二,div3</div>

</body>
</html>